/**
 * Author: Dmitry Ustimov
 * Date: 5/14/13
 * Time: 9:24 PM
 */

package com.gmail.dmitryustimov.ms.java7.mediator.classic.example.classic_example1;

public class Runway {
    private Mediator mediator;

    public Runway(Mediator mediator) {
        this.mediator = mediator;
        mediator.setLandingStatus(true);
    }

    public void land() {
        System.out.println("Landing permission granted...");
        mediator.setLandingStatus(true);
    }

    public void noLand() {
        System.out.println("Landing is not allowed!");
        mediator.setLandingStatus(false);
    }
}
